<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>伪元素</title>
    <style>
      .box1::before {
        content: "大家好";
      }
      .box1::after {
        content: "宁在春";
      }
    </style>
  </head>
  <body>
    <div class="box1">我是周杰伦</div>
  </body>
</html>
